import random


class DaliyException(Exception):
    pass


class Daliylife():

    def routine(self, getup):
        print('%s点起床' % getup)
        if 7 <= getup <= 9:
            raise Exception('起床太晚了')
        elif 9 <= getup <= 12:
            raise Exception('太阳晒屁股了')
        elif 12 <= getup <= 18:
            raise Exception('两眼一睁，天色已黑')
        elif 5 <= getup <= 7:
            print('早睡早起，必成高富帅')
        else:
            pass


dl = Daliylife()
t = random.randrange(6, 17)
try:
    dl.routine(t)
except Exception as e:
    print(e)
